package com.sg.model.base.po;

import com.baomidou.mybatisplus.annotation.*;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;

import lombok.experimental.Accessors;

import com.sg.framework.common.po.BaseEntity;
import jakarta.validation.constraints.NotNull;

import java.io.Serial;
import java.io.Serializable;
import java.io.Serial;
import java.util.Date;

/**
 * 备注：超级管理员利用角色实现；员工、学生、家长等是原始身份，原始身份只有一个；有空间，有应用
 *
 * @author xxx
 */
@Data
@Accessors(chain = true)
@TableName("oms_framework_original_role_member")  //1-2-09身份人员表
public class OriginalRoleMember implements Serializable {
    @Serial
    private static final long serialVersionUID = 1L;


    /**
     * 身份人员ID
     */
    @TableId(value = "original_role_member_id", type = IdType.ASSIGN_UUID)
    @NotNull(message = "originalRoleMemberId不能为空")
    private String originalRoleMemberId;
    /**
     * 账号ID
     */
    @TableField(value = "user_id")
    @NotNull(message = "账号ID不能为空")
    @Schema(description = "账号ID")
    private String userId;
    /**
     * 成员ID
     */
    @TableField(value = "member_id")
    @NotNull(message = "成员ID不能为空")
    @Schema(description = "成员ID")
    private String memberId;
    /**
     * 身份角色ID
     */
    @TableField(value = "role_id")
    @NotNull(message = "身份角色ID不能为空")
    @Schema(description = "身份角色ID")
    private String roleId;
    /**
     * 身份角色编码
     */
    @TableField(value = "role_code")
    @NotNull(message = "身份角色编码不能为空")
    @Schema(description = "身份角色编码")
    private String roleCode;
    /**
     * 备注首位字母
     */
    @TableField(value = "first_letter")
    @NotNull(message = "备注首位字母不能为空")
    @Schema(description = "备注首位字母")
    private String firstLetter;
    /**
     * 关系建立来源 STATION_INVITATION:站内邀请 NVITATION_OUTSIDE:站外邀请 INDEPENDENT_PARTICIPATION:自主加入 SET_WITHIN_ORG:组织内设定
     */
    @TableField(value = "source")
    @NotNull(message = "关系建立来源不能为空")
    @Schema(description = "关系建立来源")
    private String source;
    /**
     * 是否异动 TRUE:是 FALSE:否
     */
    @TableField(value = "is_transaction")
    @NotNull(message = "是否异动不能为空")
    @Schema(description = "是否异动")
    private String isTransaction;
    /**
     * 主体生命周期 CURRENTLY_VALID:当前有效 EDITING:正在编辑 ARCHIVING:历史存档
     */
    @TableField(value = "subject_life_cycle")
    @NotNull(message = "主体生命周期不能为空")
    @Schema(description = "主体生命周期")
    private String subjectLifeCycle;
    /**
     * 是否存档 TRUE:是 FALSE:否
     */
    @TableField(value = "is_archive")
    @NotNull(message = "是否存档不能为空")
    @Schema(description = "是否存档")
    private String isArchive;
    /**
     * 操作人就职记录ID
     */
    @TableField(value = "operation_induction_id")
    @NotNull(message = "操作人就职记录ID不能为空")
    @Schema(description = "操作人就职记录ID")
    private String operationInductionId;
    /**
     * 创建人就职记录ID
     */
    @TableField(value = "create_induction_id")
    @NotNull(message = "创建人就职记录ID不能为空")
    @Schema(description = "创建人就职记录ID")
    private String createInductionId;
    /**
     * 存档人就职记录ID
     */
    @TableField(value = "archive_induction_id")
    @NotNull(message = "存档人就职记录ID不能为空")
    @Schema(description = "存档人就职记录ID")
    private String archiveInductionId;
    /**
     * 发布人就职记录ID
     */
    @TableField(value = "release_induction_id")
    @NotNull(message = "发布人就职记录ID不能为空")
    @Schema(description = "发布人就职记录ID")
    private String releaseInductionId;
    /**
     * 操作时间
     */
    @TableField(value = "operate_time")
    @NotNull(message = "操作时间不能为空")
    @Schema(description = "操作时间")
    private Date operateTime;
    /**
     * 创建时间
     */
    @TableField(value = "create_time")
    @NotNull(message = "创建时间不能为空")
    @Schema(description = "创建时间")
    private Date createTime;
    /**
     * 发布时间
     */
    @TableField(value = "release_time")
    @NotNull(message = "发布时间不能为空")
    @Schema(description = "发布时间")
    private Date releaseTime;
    /**
     * 存档时间
     */
    @TableField(value = "archive_time")
    @NotNull(message = "存档时间不能为空")
    @Schema(description = "存档时间")
    private Date archiveTime;
    /**
     * 失效类型 FREEZE:冻结 OTHER:其他
     */
    @TableField(value = "invalid_type")
    @Schema(description = "失效类型")
    private String invalidType;
    /**
     * 是否失效 TRUE:是 FALSE:否
     */
    @TableField(value = "is_invalid")
    @NotNull(message = "是否失效不能为空")
    @Schema(description = "是否失效")
    private String isInvalid;
    /**
     * 失效原因
     */
    @TableField(value = "invalid_reason")
    @Schema(description = "失效原因")
    private String invalidReason;
    /**
     * 失效时间
     */
    @TableField(value = "invalid_time")
    @Schema(description = "失效时间")
    private Date invalidTime;
    /**
     * 是否作废 TRUE:是 FALSE:否
     */
    @TableField(value = "is_valid")
    @NotNull(message = "是否作废 不能为空")
    @Schema(description = "是否作废 ")
    private String isValid;
    /**
     * 创建于空间ID
     */
    @TableField(value = "space_id")
    @NotNull(message = "创建于空间ID不能为空")
    @Schema(description = "创建于空间ID")
    private String spaceId;
    /**
     * 创建于联盟应用ID
     */
    @TableField(value = "app_id")
    @NotNull(message = "创建于联盟应用ID不能为空")
    @Schema(description = "创建于联盟应用ID")
    private String appId;
}
